import { ipcMain, BrowserWindow } from 'electron'

export function setupWindowHandlers(): void {
  ipcMain.on('window.close', () => {
    const win = BrowserWindow.getFocusedWindow()
    win?.close()
  })

  ipcMain.on('window.openConsole', () => {
    const win = BrowserWindow.getFocusedWindow()
    if (win) {
      win.webContents.openDevTools({ mode: 'right' })
    }
  })
} 